home *** CD-ROM | disk | FTP | other *** search
/ Languguage OS 2 / Languguage OS II Version 10-94 (Knowledge Media)(1994).ISO / language / pcpil / pidoc7.txt < prev    next >
Text File  |  1994-02-28  |  41KB  |  1,077 lines

  1. Chapter 10. FONT EDITOR
  2.  
  3. PILOT fonts can be used to display text in a wide variety of type sizes and 
  4. styles. Several fonts are included with PILOT.  The font editor allows you to 
  5. create new or modify existing fonts.  Within a PILOT program the NS: 
  6. statement is used to select the font to be used at any particular point. 
  7. Fonts are supported in any of the graphics screen modes (modes 4-16).  
  8.  
  9. A font is stored in a disk file with a suffix of ".PIF". Each font contains 
  10. 96 user-designed characters, corresponding to the characters with ASCII codes 
  11. 32 through 127.  This includes all the standard letters, numbers, and 
  12. punctuation characters.  
  13.  
  14. Each character can be up to 24 pixels high and 24 pixels wide.  The 
  15. individual character widths are used for proportional spacing. In addition to 
  16. a width for each character, each font has a default character cell height and 
  17. width. The default character cell size is used for row and column addressing.  
  18.  
  19. Each character is made up of a grid of pixels. Each pixel can be transparent, 
  20. or one of three colors. Color numbers are 1,2 and 3, corresponding to the 
  21. three foreground colors of mode 4 or 5. In higher resolution EGA modes the 
  22. three colors can be assigned to any of the 16 or 64 colors available. A font 
  23. can be designed in one color or in three colors. In a one color font, color 
  24. number 3 is normally used. This permits the use of the TS: foreground command 
  25. or the "#" foreground character for text color changes. Multi-colored fonts 
  26. can be used to create special effects, such as shadow or outline fonts, or as 
  27. small graphics.  
  28.  
  29. When displaying user-designed fonts, PILOT uses character 127 as the cursor. 
  30. It is recommended that character 127 be a vertical bar, one pixel wide in the 
  31. leftmost column of the character cell extending from the top of the tallest 
  32. character to the bottom of the lowest character.  
  33.  
  34.  
  35. USING THE FONT EDITOR 
  36.  
  37. The font editor, FE, is used to create and modify fonts.  FE stores a font in 
  38. a file on disk for use in a PILOT program.  To use FE, enter: 
  39.  
  40.        FE name
  41.  
  42. where "name" is the name of the file you wish to modify or create. A suffix 
  43. of ".PIF" is automatically appended to the end of the filename and need not 
  44. be typed.  To use a file extension other than ".PIF" enter the entire file 
  45. name on the command line. The file name may include a drive and/or path 
  46. designation. If the file does not already exist, a new file is created. 
  47. Otherwise, FE verifies that file is a valid font file, created by FE. If the 
  48. file is not a font file, FE assumes that the file is a graphics image file in 
  49. bit-mapped format. It could have been produced by GIE, the PILOT GSX: 
  50. statement, or the BSAVE utility.  In any case, when the file subsequently is 
  51. saved, it will be saved as a font file.  
  52.  
  53. Since FE can read in graphics image files, a previously designed font can be 
  54. modified even if it wasn't created via FE.  Simply display all the characters 
  55. in the font on the screen, and use a screen capture utility such as BSAVE to 
  56. save the contents of the screen in a file.  
  57.  
  58.  
  59. MAIN MENU 
  60.  
  61. When FE is first entered, the main menu is displayed.  From the main menu, 
  62. there are four options.  The desired option is chosen with the function keys.  
  63. The functions keys and their operations are shown below.  
  64.  
  65.  
  66. F1 - edit characters 
  67.  
  68. F1 transfers to select mode. Select mode is used to choose an individual 
  69. character to edit.  
  70.  
  71.  
  72. F2 - change global parameters 
  73.  
  74. F2 brings up the menu to set character cell size and perform color 
  75. modification of the font.  
  76.  
  77. F10 - save font 
  78.  
  79. F10 from the main menu saves the font on disk. A backup copy of the file is 
  80. made, and saved in the file "name.bak", where "name" is the name of the file 
  81. being edited, without the file extension. If an error occurs while saving the 
  82. file, the previous version will be in the backup file.  
  83.  
  84.  
  85. Shift F10 - abandon font 
  86.  
  87. Shift F10 exits the font editor without saving the file.  All changes made to 
  88. the font during the current editing session are lost.  
  89.  
  90.  
  91. SELECT MODE 
  92.  
  93. Select mode is used to choose the character to be edited.  When in select 
  94. mode, the complete font is displayed on the screen.  One of the font 
  95. characters is always highlighted.  The highlighted character is called the 
  96. "current character".  On the left-hand side of the display there is a solid 
  97. bar with a number and two boxes in it.  The number is the ASCII value of the 
  98. current character.  The lower box shows the current character in the normal 
  99. 40 column text font, for use as a reference.  The upper box is called the 
  100. "edit box".  The character in this box is called the "edit character".  
  101.  
  102. Action in select mode is controlled by the cursor and function keys. The 
  103. possible operations are shown below.  
  104.  
  105.  
  106. ARROW KEYS - change current character 
  107.  
  108. Selection of the current character is done with the arrow keys.  The arrow 
  109. keys wrap around horizontally and vertically to make it easier to choose the 
  110. desired character.  
  111.  
  112.  
  113. F3 - pick from font
  114.  
  115. F3 copies the current character to the edit character box.  The width of the 
  116. current character is also copied.  
  117.  
  118.  
  119. F4 - put to font
  120.  
  121. F4 copies the edit character to the current character.  The width is also 
  122. copied.  
  123.  
  124.  
  125. F5 - micro-adjust 
  126.  
  127. F5 enters micro-adjust mode. Micro-adjust mode is used only for copying a 
  128. character to the edit character box.  In micro-adjust mode, the cursor keys 
  129. move the highlighted area by one pixel, rather than by one character. Also, 
  130. the Home, PgUp, PgDn, and End keys can be used to move the highlighted area 
  131. diagonally.  In micro-adjust mode, F3 picks the currently highlighted 
  132. character and copies it to the edit box. F10 returns to select mode. F9 
  133. transfers to fat-bits mode. An exit from fat-bits mode, returns to select 
  134. mode, rather than micro-adjust mode.  
  135.  
  136. Micro-adjust mode is used for editing a font that was read in from a graphics 
  137. image file.  In this case, the characters might not be in the right locations 
  138. for a font file.  Using the micro-adjust keys, a character can be copied to 
  139. the select character box.  Back in select mode, the character can be copied 
  140. back to the font, in the proper character position.  
  141.  
  142. F9 - go to Fat-bits mode 
  143.  
  144. F9 transfers to fat-bits mode to edit the select character.  
  145.  
  146. F10 - exit 
  147.  
  148. F10 returns to the main menu.  
  149.  
  150. Esc - undo 
  151.  
  152. Escape undoes the action of the last pick, put, or undo. Warning: only the 
  153. last pick, put, or undo can be undone.  
  154.  
  155.  
  156. FAT-BITS MODE 
  157.  
  158. F9 from select or micro-adjust mode transfers to fat-bits mode. In fat-bits 
  159. mode, the edit character can be edited.  The edit character is shown in an 
  160. expanded format so that individual pixels can be identified and edited.  
  161. Within the expanded font character, a small box-shaped pixel cursor shows the 
  162. position of the currently selected pixel within the character grid.  
  163.  
  164. When in fat-bits mode, there are a number of indicators on the screen. The 
  165. edit character is displayed in its normal size in the lower left-hand corner 
  166. of the display. The character is bracketed by bars that indicate its current 
  167. width.  The character width is used to determine placement of the next 
  168. character when this character is displayed in a PILOT program.  Normally the 
  169. width should be set to one or more pixels to the right of the rightmost pixel 
  170. of the character shape.  If the width is less than the actual size of the 
  171. character, the bars will overlay the character.  This is permissible and 
  172. indicates that the following character might  intersect this character when 
  173. displayed. Immediately below the character are five indicators, described 
  174. below.  
  175.  
  176.  
  177. Width - character width
  178.  
  179. The current width of the character is shown, in number of pixels.  When fat-
  180. bits mode is entered, the width is set to the current width of the edit 
  181. character.  
  182.  
  183.  
  184. Set - pixel setting color and stream mode
  185.  
  186. This number is the current set pixel color.  In addition to a color number, a 
  187. plus or minus sign may be displayed.  A plus sign indicates that stream set 
  188. mode is on.  When stream set mode is on, the cursor keys automatically set 
  189. each pixel as the cursor moves from one pixel to another.  A minus sign 
  190. following the current drawing color indicates that stream clear mode is on.  
  191. When stream clear mode is on, the cursor key automatically clears each pixel 
  192. to the background color as the cursor moves from one pixel to another.  
  193.  
  194.  
  195. Mode - font editor screen mode
  196.  
  197.  
  198. Back - current background color  
  199.  
  200.  
  201. Char - character indicator
  202.  
  203. The ASCII value from 32 to 127, and the standard 40 column text 
  204. representation of the currently selected character.  These indicators are 
  205. displayed only as a reference.  Note that the character shown is the 
  206. currently highlighted character in select mode, not necessarily the edit 
  207. character.  If you change the current character after picking the edit 
  208. character, this character will not be the same as the edit character.  
  209.  
  210.  
  211. Baseline Markers
  212.  
  213. Horizontal and vertical baseline markers can be set. These markers are saved 
  214. when you exit to select mode, and are restored the next time you return to 
  215. fat-bits mode.  Baseline markers are used only as reference points on the 
  216. fat-bits grid to facilitate character editing.  
  217.  
  218.  
  219. FAT BITS MODE KEYS  
  220.  
  221. The fat-bits mode keys are shown below.  
  222.  
  223.  
  224. 1, 2, 3 - choose drawing color 
  225.  
  226. Pressing 1, 2, or 3 sets the drawing color to that color.  
  227.  
  228.  
  229. 4, 5 - set screen mode 
  230.  
  231. Pressing 4 or 5 sets the screen mode.  
  232.  
  233.  
  234. PLUS and MINUS - change background color 
  235.  
  236. The + key increments the background color.  The - key decrements the 
  237. background color.  
  238.  
  239.  
  240. ARROW KEYS, DIAGONAL KEYS - move cursor 
  241.  
  242. The arrow keys and Home, PgUp, PgDn, and End keys are used to move the pixel 
  243. cursor.  The diagonal keys are useful when stream set or clear mode is on, to 
  244. draw diagonal lines.  
  245.  
  246.  
  247. F1 - set a pixel 
  248.  
  249. F1 sets the pixel at the pixel cursor to the current drawing color.  F1 also 
  250. turns off either stream mode, if set.  
  251.  
  252.  
  253. Shift-F1 - toggle stream set mode 
  254.  
  255. Shift-F1 toggles screen set mode.
  256.  
  257.  
  258. F2 - clear a pixel 
  259.  
  260. F2 clears the pixel at the cursor to the background color.  F2 also turns off 
  261. either stream mode.  
  262.  
  263.  
  264. Shift-F2 - toggle stream clear mode 
  265.  
  266. Shift-F2 toggles the stream clear mode.
  267.  
  268.  
  269. F3 - toggle horizontal mark 
  270.  
  271. F3 toggles a baseline mark in the current cursor row.  
  272.  
  273.  
  274. F4 - toggle vertical mark 
  275.  
  276. F4 toggles a baseline mark in the current cursor column.  
  277.  
  278.  
  279. F5 - invert the font character 
  280.  
  281. F5 inverts the color of each pixel in the character.  
  282.  
  283.  
  284. Shift-F5 - clear font character 
  285.  
  286. Shift-F5 clears the entire character to the background color.  
  287.  
  288.  
  289. F6 - rotate character 
  290.  
  291. F6 rotates the font character counter-clockwise 90 degrees.  F6 also clears 
  292. either stream mode, if set.  
  293.  
  294.  
  295. Shift-F6 - reflect character 
  296.  
  297. Shift-F6 reflects the font character about the vertical axis.  In conjunction 
  298. with the F6 key, the character can be reflected about the horizontal axis 
  299. also. Shift-F6 clears all stream mode.  
  300.  
  301.  
  302. F7 - horizontal roll left
  303.  
  304. F7 rolls the font character to the left by one column.  The leftmost column 
  305. becomes the rightmost column.  All of the roll keys clear either stream mode, 
  306. if set.  
  307.  
  308.  
  309. Shift-F7 - horizontal roll right
  310.  
  311. Shift-F7 rolls the font character to the right by one column.  The rightmost 
  312. column becomes the leftmost column.  
  313.  
  314.  
  315. F8 - vertical roll up 
  316.  
  317. F8 rolls the font character up by one row.  The top row becomes the bottom 
  318. row.  
  319.  
  320.  
  321. Shift-F8 - vertical roll down 
  322.  
  323. Shift-F8 rolls the font character down by one row.  The bottom row becomes 
  324. the top row.  
  325.  
  326.  
  327. F9 - decrease width 
  328.  
  329. F9 decreases the width of the character being edited by one pixel. The width 
  330. indicators change to reflect the new width. The character itself is not 
  331. changed.  The minimum width is 0 pixels. The width is used to determine the 
  332. placement of any character which is displayed immediately after this 
  333. character.  
  334.  
  335.  
  336. Shift-F9 - increase width 
  337.  
  338. Shift-F9 increases the width of the character being edited.  The maximum 
  339. width is 255.  
  340.  
  341.  
  342. F10 - return to select mode 
  343.  
  344. F10 returns to select mode.  The character being edited is copied back to the 
  345. edit character box.  The width is also copied. To copy the edited character 
  346. back to the font as the current character use F4.  
  347.  
  348.  
  349. CHANGING GLOBAL PARAMETERS 
  350.  
  351. From the main menu, the F2 key transfers to the global parameter menu from 
  352. which the following keys may be used: 
  353.  
  354.  
  355. F1, F2, F3 - set substitution colors 
  356.  
  357. A color substitution table can be built to make a mass change of all colors 
  358. in the font. F1, F2 and F3 are used to set the new color for all pixels 
  359. currently of colors 1,2 and 3, respectively. The substitution colors may be 
  360. 0, 1, 2 or 3. Substituting to color 0 has the effect of erasing pixels. The 
  361. prompt line indicates the current settings for each substitution color. F5 
  362. can be used to preview the effect of the color substitution table.  
  363.  
  364.  
  365. F5 - view new colors 
  366.  
  367. The F5 key causes the whole font to be displayed with the new colors 
  368. substituted in.  It does not change the font permanently.  
  369.  
  370.  
  371. F6 - save new colors 
  372.  
  373. F6 causes the whole font to be displayed with the new colors substituted in. 
  374. Once displayed, a prompt is asks if you are sure you want to save the font 
  375. with the new colors.  If you respond with a 'y', the change is made 
  376. permanently.  
  377.  
  378.  
  379. F7 - set cell width 
  380.  
  381. F7 is used to set the default cell width for the font.  The cell width must 
  382. be between 1 and 255.  
  383.  
  384.  
  385. F8 - set cell height 
  386.  
  387. F8 is used to set the default cell height for the font.  The cell height must 
  388. be between 1 and 255.  
  389.  
  390.  
  391. F10 - return to main menu 
  392.  
  393.  
  394. Chapter 12. TOUCH SCREEN
  395.  
  396.  
  397. The touch screen is supported in two ways: "touch key mode" and "touch 
  398. coordinate mode".  The two modes can be intermixed in any manner within a 
  399. program. The touch key mode is used to detect selection of a pre-defined 
  400. target on the display screen. The touch coordinate mode can be used to detect 
  401. the exact location of a touch in graphics or text coordinates. The touch 
  402. coordinate mode also permits the program to check for a touch without 
  403. stopping to wait for a touch.  
  404.  
  405.  
  406. TOUCH KEY MODE
  407.  
  408. The user can define up to 60 TOUCH KEYS on the display screen.  Each touch 
  409. key is a rectangular block of character cells. The smallest possible touch 
  410. key is one character cell; the largest is the entire display screen. Touch 
  411. keys may overlap in any manner and need not fill the entire display area.  
  412. PILOT does not take any automatic action to make the touch keys visible.  The 
  413. user can choose to do so by creating an appropriate display which outlines or 
  414. highlights the touch keys in any desired manner.  Internally, PILOT keeps a 
  415. table of all current touch keys. Each touch key is identified by a number 
  416. from 1 to 60. The following statements can be used to control the touch key 
  417. table: 
  418.  
  419.  
  420. TS:Kn  - define touch key
  421.  
  422. The current viewport is defined to be touch key n. n may be a number from 1 
  423. to 60. The K command would normally be intermixed with other commands on the 
  424. TS: statement. The following example defines two touch keys, number 2 and 
  425. number 3. Each one has a label displayed in it.  
  426.  
  427.      TS: V2,7,5,9;K2;Astart; V40,50,6,12;K3;Astop
  428.      TS:K0  - remove all touch key definitions 
  429.  
  430. The touch key table is erased. No touch keys remain defined.  
  431.  
  432. ACCEPT POINT 
  433.  
  434. To accept touch key input use the ACCEPT POINT statement, or the ACCEPT POINT 
  435. EXCLUSIVE statement.  
  436.  
  437.  
  438. AP:  - accept point 
  439.  
  440. Accept point waits for touch screen or keyboard input.  
  441.  
  442.  
  443. APX:  - accept point exclusive 
  444.  
  445. Accept point exclusive waits for touch screen input only.  
  446.      
  447. The ACCEPT POINT works like a normal accept in that the program waits for 
  448. student input.  In the case of AP: the student can either type a reply on the 
  449. keyboard, followed by the ENTER key, or touch the screen. In the case of APX: 
  450. the student must touch the screen to end the accept.  
  451.      
  452. In either case, if the student touches the screen, within a touch key, a 
  453. "good beep" sounds and  the student answer buffer (%B) is set to the touch 
  454. key number enclosed in square brackets, (eg. "[12]" ). If the student touches 
  455. outside all touch keys then a "bad beep" sounds and the answer buffer is set 
  456. to "[0]".  
  457.  
  458. If touch keys overlap, and a touch occurs within more than one touch key, 
  459. then the lower touch key number is returned.  
  460.  
  461. Like the normal Accept statement, the AP: and APX: statements may contain 
  462. variable names as arguments. For example: 
  463.         
  464.        APX: #Q
  465.  
  466. sets the numeric variable Q to the touch key number selected by the student, 
  467. and sets the string variable %B to the same number, enclosed in  [ ].  
  468.  
  469. Example: Waits until the student touches a touch key, giving a bad beep on 
  470. all other touches that may occur first.  
  471.  
  472.        APX: #Q
  473.        J(Q=0):@A
  474.  
  475. The AP: statement allows the student to reply as to a normal Accept, using 
  476. the keyboard, or by touching the screen. The program can detect which 
  477. occurred by checking for the square brackets in the answer buffer as follows: 
  478.  
  479.        AP:
  480.        M:[&]
  481.        TY: touch screen used.
  482.        TN: keyboard used.
  483.  
  484. The AP: and APX: op codes are subject to response timing in the same manner 
  485. as the A: op code. The response time limit is set by a statement such as 
  486.  
  487.        P: T5    (set max response time to 5 sec)
  488.  
  489. Also, the function TIM(0) returns the actual student response time for the 
  490. last Accept statement.  
  491.  
  492. If the ESCAPE option is enabled on the P: statement (P:E), then touch key 
  493. number 1 has special significance. Touch key 1 is treated similarly to the 
  494. student entering an "@" character, in that a USE is issued to label *SYSX. 
  495. This can be used to implement a "hot spot" on the screen, which would invoke 
  496. asynchronous events like help, menus, reviews etc.  
  497.  
  498.  
  499. TOUCH COORDINATE MODE
  500.  
  501. The PNT function is used to control touch coordinate mode. PNT can be used in 
  502. any expression context. The format of the PNT function is as follows.  
  503.  
  504.        PNT(n)
  505.  
  506. where n is a value of 0, 1 or 2.  
  507.  
  508. PNT must be called first with an argument of 1 to enable touch coordinate 
  509. mode: 
  510.  
  511.        C: X = PNT(1)
  512.  
  513. Once this statement is executed, the touch screen is active.  The program can 
  514. test for a touch having happened by  statement such as: 
  515.  
  516.        J(PNT(0)):TOUCH
  517.  
  518. The returned value is 0 if no touch has occurred, or 1 if a touch has 
  519. occurred. If the value is 1, then four system variables have been set to 
  520. reflect the location of the touch: 
  521.  
  522. %X  - the graphics x-pixel location of the touch
  523. %Y  - the graphics y-pixel location of the touch
  524. %R  - the text row number of the touch
  525. %C  - the text column number of the touch
  526.  
  527. These system variables are set in the ranges that suit the current screen 
  528. display mode.  The program can use these variables in any expression context.  
  529.  
  530. Whether or not a touch is returned by the PNT(0) function, the touch screen 
  531. remains active. The program can deactivate the touch screen by executing the 
  532. function: 
  533.  
  534.        C: X = PNT(2)
  535.  
  536. Example: This code sequence places an asterisk at any point touched by the 
  537. user.  
  538.  
  539.        C:I=PNT(1)
  540.        *LOOP  J(PNT(0)=0):LOOP
  541.        TS:G(%C),(%R);A*
  542.        J:LOOP
  543.  
  544.  
  545. Chapter 13. SIMULATED SPEECH
  546.  
  547.  
  548.        SS: n1, n2, n3 . . .
  549.  
  550. n1, n2 and n3 are decimal numbers which represent the speech vocabulary chip 
  551. addresses of the words to be played back.  Each number is separated from the 
  552. previous one by a comma or semi-colon.  
  553.  
  554. Multiple words on one line are spoken as a sentence.  
  555.  
  556. Example: simulated speech 
  557.  
  558.        SS: 1                 (say one word)
  559.        SS: 5,3,7             (say three words)    
  560.  
  561. Chapter 14. VIDEO DISC SUPPORT
  562.  
  563.        VS: command-list
  564.  
  565. A PILOT program can control the operation of the attached video disc player. 
  566. The visual output of the player can be displayed on the screen in combination 
  567. with the computer-generated text or graphic display.  
  568.  
  569. The video disk image can be considered to be "behind" the computer display 
  570. image. The program controls which parts of the video image and which parts of 
  571. the computer display image are visible by selecting a color on the computer 
  572. display image to be transparent. For example, if black is transparent, then 
  573. the video disk image shows through wherever the computer display image would 
  574. be black. Other colors in the computer display appear to be overlayed on the 
  575. video disk image.  
  576.  
  577. The video disk unit can be controlled by the VS: , or VIDEO SUPPORT 
  578. statement. VS: has a syntax similar to the TS: or G: statements, in that it 
  579. can contain a list of a number of individual commands. If there is more than 
  580. one command on a VS: statement, each must be separated from the previous one 
  581. by a semi colon. For example: 
  582.  
  583.        VS: L1; A3; P100,675
  584.  
  585. In the following command descriptions, n represents a number, a variable or 
  586. an expression.  
  587.  
  588. Video disk frame numbers run from 1 to (approximately) 54000.  The possible 
  589. commands are a follows: 
  590.  
  591. An - select audio channels
  592.  
  593. Set audio control for subsequent play command, A0 means silence, A1 means 
  594. left track, A2 means right track, A3 means both tracks. This may be issued 
  595. prior to, or during a play command to turn the sound off or on at any time.  
  596.  
  597. Cm,p - mode and palette select
  598.  
  599. Set interlace mode and color palette selection. m=0 disables interlace mode, 
  600. m=1 enables it. Interlace mode should be enabled during video display and 
  601. disabled during graphics display to enhance the visual effect.  p=0 selects 
  602. normal color palette and p=1 selects large color palette.  
  603.  
  604. The color palette determines how the transparency color number on the Tn 
  605. command below is interpreted. In normal color palette mode the transparency 
  606. color number is assumed to be in the range 0-15 and is interpreted as a color 
  607. number corresponding to the 16 default colors. In the large color palette 
  608. mode the transparency color is assumed to be in the range 0-63 and is 
  609. interpreted as a color number as defined by the EGA color palette.  
  610.  
  611. Note that the "TS:Fn,m" command can be used to access the large color palette 
  612. of the EGA.  
  613.  
  614. Dn - display player frame information 
  615.  
  616. Control the player-generated frame number display. D0 means frame number is 
  617. not displayed on the screen, D1 means frame number is displayed on the screen 
  618. whenever a video image is displayed. This command is provided for debugging 
  619. purposes since it shows what frame number is currently being displayed.  
  620.  
  621. Fn - still frame
  622.  
  623. Search for frame number n, then play it as a still frame.  
  624.  
  625. H0 - soft system halt 
  626.  
  627. Command the display system to do a soft stop. The soft stop command should be 
  628. issued prior to calling an external program.  It causes all video, touch and 
  629. sound commands to stop at a logical point. Then software which expects a 
  630. standard graphics adapter may be executed.  
  631.  
  632. H1 - restart after soft system halt 
  633.  
  634. Command the display system to resume special function modes after a previous 
  635. soft stop.  This command leaves the system in a ready state with no video, 
  636. touch or sound turned on.            
  637.  
  638. Ln - load or unload disk 
  639.  
  640. L0 means unload (spin down) L1 means load (spin up).  An L1 command MUST be 
  641. issued prior to any attempt to play any video scenes. Once this command is 
  642. issued, the PILOT program pauses until the disc is up to speed, or an error 
  643. occurs. After this command the program should test the player status via the 
  644. VFN function to insure that the disc unit is ready to go.  
  645.  
  646. Mn - enable or disable manual controls
  647.  
  648. The video disc player has manual remote controls. They can be disabled or 
  649. enabled under software control. M0 means disable, M1 means enable.  
  650.  
  651. Pf,t - play a video scene from frame f to frame t. 
  652.  
  653. The video player plays the designated sequence of video frames. When frame 
  654. number t is reached the player continues to show frame t in still frame mode.  
  655.  
  656. If f is less than t the scene is played forward. 
  657.  
  658. If f is greater than t, then the scene is played backwards.  If the first 
  659. frame number, f is equal to 0, then the play begins at the current frame 
  660. number and plays forward or backward to frame number t.  
  661.  
  662. The An command, shown above, can be executed prior to the play command to 
  663. control whether the audio portion is present.  
  664.  
  665. An Rn command, shown below, can be executed prior to the play command to set 
  666. the play rate.  
  667.  
  668. The program proceeds immediately after issuing this command to the video 
  669. disc. It does not wait until the scene is complete.  If you wish the program 
  670. to wait for the scene to complete see the VST and VFN functions below.  
  671.  
  672. A play in progress can be stopped at any time by a still frame command, an 
  673. unload command, or a stop command.  
  674.  
  675. Rn - set play rate 
  676.  
  677. Set the play speed for subsequent play command. The value of n is in terms of 
  678. percent of normal speed, from 1 to 255. If 0<n<100 then the play rate is 
  679. slowed down to n percent of normal. If n>100 then play rate is increased to n 
  680. percent.  R100 sets the play rate to normal. No audio is played when the play 
  681. rate is slower or faster than normal.  
  682.  
  683. Sn -  single frame step 
  684.  
  685. S0 means step backward one frame, S1 means step forward one frame.  
  686.  
  687. T; - turn off transparency 
  688.  
  689. Set no computer display colors to transparent, so only the computer display 
  690. is visible, the video image behind it is not visible.  
  691.  
  692. Tn - set color n to transparent 
  693.  
  694. The video image shows through the computer display image wherever the 
  695. computer display image is color number n. See the "Cm,p" command above for 
  696. information on the value of n.  
  697.  
  698. Un - select video player unit n 
  699.  
  700. When more than one player is attached, this command selects the player to 
  701. which commands are sent. Player 1 is the default.  Once a player unit is 
  702. selected, all player commands are routed to that player.  However, it is 
  703. possible to be showing a scene from one player and giving commands to another 
  704. by combinations of the Un and Vn commands.  
  705.  
  706. Vn - select video player output to display 
  707.  
  708. When more than one player is attached, this command selects the player whose 
  709. output is displayed. Player 1 is the default.  It is possible to be showing a 
  710. scene from one player and giving commands to another by combinations of the 
  711. Un and Vn commands.  
  712.  
  713.  
  714. X - stop a play-in-progress
  715.  
  716. The play command stops at the current frame and the current frame is played 
  717. as a still frame.  
  718.  
  719.  
  720. VIDEO FUNCTIONS
  721.  
  722. Each of these functions returns a number. Each can be used in any expression 
  723. context.  
  724.  
  725.  
  726. I = VFN(n)   - frame number
  727.  
  728. Returns current video frame number for player n. In a system with one player 
  729. n should be equal to 1.  
  730.  
  731.  
  732. I = VST(n)  - returns current status of player n
  733.  
  734. Returns the play status of player n. The status may be one of the following 
  735. values: 
  736.  
  737.        -1  indicates an error condition
  738.         0  disc not up to speed (parked/unloaded)
  739.         1  disc up to speed, not playing (loaded)
  740.         2  disc playing a still frame (stopped)
  741.         3  disc playing a scene
  742.  
  743.  
  744. Examples: 
  745.  
  746.        R: set up to show video in black areas
  747.        VS:T0  
  748.  
  749.  
  750.        R: spin up disc and check whether okay
  751.        VS:L1           
  752.        T(VST(1)<2):Player is not up to speed!
  753.  
  754.  
  755.        R: play a scene with sound track 2.
  756.        VS: A2; P100,575     
  757.        R: Wait until the scene is done.
  758.        *Loop  J(VST(1)=3):Loop  
  759.      
  760.  
  761.        R: play from current frame, 50% speed
  762.        VS: R50; P0,54000     
  763.        R: Wait until at from 1000.
  764.        *Loop1 J(VST(1)=3 & VFN(1)<1000):Loop1   
  765.        VS: X                                      
  766.        R: step 3 frames
  767.        VS: S1; S1; S1                           
  768.  
  769.  
  770. Appendix A.  Language Summary
  771.  
  772. Appendix A: PILOT LANGUAGE SUMMARY
  773.  
  774. STATEMENTS
  775.             
  776. A: [variables]                               accept answer
  777. AS:                                          accept single
  778. AH:                                          accept hold cursor
  779. AX:                                          accept with default key codes
  780. AJ:                                          accept with type-ahead
  781. AP:                                          accept touch or keyboard input
  782. APX:                                         accept touch screen input 
  783.  
  784. C: var = expr                                compute and assignment
  785.  
  786. D: var(len),...                              create arrays and/or strings
  787. DX: v$(len)                                  create aligned string
  788.  
  789. E: [label]                                   end subroutine or program
  790.  
  791. FX: [name]                                   open or close a file
  792. FI: byte,var$                                file in (read from file)
  793. FO: byte,expr                                file out (write to file)
  794.                    
  795. FXH: size                                    initialize heap file
  796. FIH: byte,vr$                                in heap (read from heap)
  797. FOH: byte,expr                               out heap (write to heap)
  798.                    
  799. G: command-list                              turtle or sprite graphics
  800. GSX:                                         save screen internally
  801. GX:                                          restore screen
  802. GX: name                                     display graphics image from file 
  803. GSX: name                                    save graphics image to file name
  804.  
  805. J: label                                     jump to label
  806.  
  807. K: expression                                write to student records file
  808. L: name[,label]                              link to program name
  809.  
  810. M:pattern                                    match student answer 
  811. MJ:pattern                                   if NO, jump to next match
  812. MS:pattern                                   match with spelling errors
  813. MX:expression                                numeric match
  814.  
  815. N: pattern                                   new character
  816. NX: x,y ;...                                 new key
  817. NXS:                                         restore old keyboard codes
  818. NS:variable$                                 change character font
  819. NH:width,height                              change default character cell size
  820.  
  821. P: option-list                               problem start and options
  822.  
  823. PX: offset,byte                              poke byte to memory
  824. PJ: address,byte                             output byte to port address
  825.  
  826. R: remarks                                   provides program comments
  827. S: pit,dur;...                               sound
  828. SS: address,...                              simulated speech
  829.  
  830. T: text                                      type text
  831. TH: text                                     type hang (no return)
  832. TX: text                                     type clear screen
  833.  
  834. TS: screen-list                              type screen
  835.  
  836. U: label                                     use (call) subroutine
  837.                                 
  838. V: var$                                      call machine language
  839. VS: command-list                             video disc control
  840.  
  841. W: expression                                wait expr  tenths of a second
  842. WH: expression                               wait and hold character
  843.  
  844. X: expression                                execute indirect
  845.  
  846. P STATEMENT OPTIONS (P:)
  847.  
  848. S remove all spaces                 L trans to lower case
  849. U trans to upper case               G allow  GOTO command
  850. E allow ESCAPE cmd                  W clear  label  table
  851. F func key escape                   P printer-echo on
  852. An set max A: len                   Z turn off all options
  853. Tn set max A: response time
  854. Kname set keep file name for K: statement
  855.  
  856. STATEMENT LABELS
  857.  
  858. *label (alone)             *  followed by 1 to 6 characters
  859. *label stmt (before stmt)
  860.  
  861. CONDITIONALS
  862.  
  863. TY:...                execute statement if last match YES
  864. TN:...                execute statement if last match  NO
  865. TE:...                execute statement if err  condition
  866. Tn:...                (1-9) execute  if  answer counter=n
  867. T(x<3):...            execute if  expression  is true
  868. TC:...                execute if last expression was true
  869.  
  870.  
  871. MATCH PATTERNS
  872.  
  873. *  any single char                &  any sequence of chars
  874. !  alternate answer               %  match a space, or end
  875. @  items any order                ^  negation of match
  876.  
  877.  
  878. SCREEN COMMANDS (TS:)
  879.  
  880. Axx/yy  do animation            Bn   background  color
  881. Dn  delay n 60ths sec           En   erase to  color n
  882. Fn  foreground color            Gx,y   cursor goto x,y
  883. Fn,a  color palette             On   overlay/xor  mode
  884. Ln  set line spacing            Mn   screen mode (0-6)
  885. Pn  select page (0-7)           Pn,w  displ/write page
  886. Vl,r,t,b  set viewport          V;  restore viewport  
  887. Wrlud  walk one space           ;  separates items    
  888. *n(.)  repeat n times           Xn   set screen border
  889.  
  890.  
  891. GRAPHICS COMMANDS (G:)
  892.  
  893. Cn  set pen color               E  erase entire screen
  894. Cn,w  pen color width           Dx,y  draw to pixel x,y
  895. Ar,d  arc, radius r             Bx,y  solid bar
  896. Fn  forward n steps             Gx,y  turtle   goto x,y
  897. Hn  set heading                 Rn   right  n  degrees
  898. Ln  left n degrees              Xn   horizontal  scale
  899. Yn  vertical scale              *n(..)  repeat n times
  900. Pn  paint to color n            Wn  wait n 60ths sec
  901. Svar$  sprite table             Sn  sprite n current
  902. Jn  jump to sprite n            ;  separates items
  903.  
  904. SYSTEM VARIABLES
  905.  
  906. %A    answer counter         
  907. %B    answer buffer
  908. %E    jump loc of last U: return point
  909. %N    item which matched on last match
  910. %M    loc in %B which matched on last match
  911. %L    len in %B which matched on last match
  912.  
  913. VARIABLES
  914.  
  915. X  cat  WRONG  W5      simple real variables
  916. score(expr)            subscripted real variable
  917. name$                  string variable, varying length
  918. c$(pos)                single character substring
  919. hard$(pos,len)         substring specified length
  920.  
  921. Names are 1-6 bytes,  start with a letter.
  922. Upper/lower  case  are the same in a name.
  923. Arrays start at 0. Strings start at 1.
  924.  
  925. OPERATORS AND EXPRESSIONS
  926.  
  927. + add     - sub     * mul      / div    % modulo
  928. & and     ! or       ~  not    !! concatenate
  929. <    >    =    <=    >=    <>  relational
  930.  
  931. ABS ASC ATN AUX BGC CAP CHR COS CLK DEC EXP FGC  
  932. FIZ FLO INS INP INT KEY LNE LOG LEN MEM MOD OFF
  933. PEK RND RSP SEG SFL SGN SIN SPC SQR STR SWP TIM 
  934. WRD XCR XPX YCR YPX
  935.  
  936. OUTPUT CONTROL CHARACTERS
  937.  
  938. 8 LEFT        9 RIGHT       10 DOWN     11 UP
  939. 12 CLEAR     13 RETURN      14 HOME 
  940.  
  941. RUN TIME COMMANDS
  942.  
  943. P:G enables GOTO label, causes J:label
  944.  
  945. P:E enables Esc key to cause  U:SYSX
  946.  
  947. P:F enables function/cursor key to cause  U:SYSX
  948.  
  949. EZ EDITOR      EZ name.PIL       
  950.  
  951. up down right left arrows, tab move cursor
  952. HOME goto top of file               END goto end of file
  953. INS insert character                DEL delete character
  954. PG UP move up a page                PG DN move down page
  955. F1 insert line/split                F2 delete line/join 
  956. F3 pick up a line                   F4 put down a line
  957. F5 goto line/find str               F6 shift to extended
  958. F7 expand macro to text             F8 goto graphics mode
  959. F9 on-line help                     F10  save file, exit   
  960. shift F5  search and replace       
  961. shift F7  copy file into text 
  962. shift F8  enter character editor
  963. shift F9  save or print all or partial file
  964. shift F10 abandon edited file and exit
  965.  
  966. SPRITE EDITOR
  967.  
  968. F1 select sprite                    F2 select layout
  969. F3 copy to sprite                   F4 copy to image
  970. F5 load sprite table                F6 save sprite table
  971. F7 load image                       F8 save image
  972. F9 goto fat bits mode               F10 exit
  973. arrows roll graphics image 1 pixel
  974.  
  975.  
  976. SPRITE EDITOR FAT BITS MODE
  977.  
  978. F1 set a pixel                      ^F1 stream set
  979. F2 clear a pixel                    ^F2 stream clear
  980. F8 change screen mode               ^F5 clear sprite
  981. F10 exit fat bits mode
  982. + and - change background colors
  983.  
  984.  
  985. APPENDIX B: PILOT CHARACTER SET
  986.  
  987. OUTPUT CHARACTERS
  988.  
  989. PILOT allows the use of characters in the range of ascii 32 (space) through 
  990. ascii 255. On the IBM PC these are all considered "printable" characters. 
  991. That is, all are displayed on the screen if typed by a T: statement. The 
  992. characters in the range of 0 to 31 are not printable; these are reserved for 
  993. terminal control functions. (See table below.) Any control character that has 
  994. not been assigned a function is ignored completely upon output. The EZ editor 
  995. allows the user to place any character from 32 to 255 in a program file. It 
  996. does not allow characters from 0 to 31 to be put in a file. If you use a text 
  997. editor which does allow control characters to be placed in the text, you 
  998. should also avoid doing so when creating a PILOT program.  
  999.  
  1000.        CHR(8)  - backspace
  1001.        CHR(9)  - forward space
  1002.        CHR(10) - cursor down
  1003.        CHR(11) - cursor up
  1004.        CHR(12) - clear screen
  1005.        CHR(13) - return (newline)
  1006.        CHR(14) - home
  1007.  
  1008. The characters from 32 to 127 display the same in all screen modes of PILOT. 
  1009. These are as shown on pages G2 and G3 of appendix G of the BASIC manual. (You 
  1010. might consider moving those pages to this appendix for future reference.) 
  1011.  
  1012. There is a difference in what you see on the screen for 
  1013. characters in the range 128 to 255 depending on what screen mode the PILOT 
  1014. program uses. In modes 0 through 3 (the text modes) the characters displayed 
  1015. are as shown on pages G4 and G5 of appendix G of the BASIC manual.  
  1016.  
  1017. In modes 4 through 6 (the graphics modes) the characters from 128 to 255 are 
  1018. handled in a special way. These are the characters that are available for 
  1019. user defined characters (see the NEW CHARACTER statement). If you do not 
  1020. define any character patterns (that is you do not execute any N: statements) 
  1021. then the characters from 128 to 255 have unpredictable shapes and should not 
  1022. be used at all.  Once you define at least one character then the remainder of 
  1023. the characters in this range have the same shapes as the corresponding 
  1024. characters in the range 0 to 127 as shown in BASIC appendix G. You can define 
  1025. new shapes for any or all of the 128 characters in this range. You can not 
  1026. change the shapes of the characters below 128.  
  1027.  
  1028. ENTERING CHARACTERS WITH EZ
  1029.  
  1030. EZ allows the user to enter characters from 32 to 255 into the text. The 
  1031. characters from 32 to 127 are easily entered in the natural way by just 
  1032. pushing the key with the appropriately marked character on the keyboard. To 
  1033. enter characters from 128 to 255 the user first pushes the F6 key then pushes 
  1034. a second key. The character entered into the text is the value of the second 
  1035. key plus 128. For example F6 # yields the character 35+128=163 or u-accent. 
  1036. (See chart below.) If you  wish to enter several extended characters in a 
  1037. row, push SHIFT-F6.  Then all characters are changed in the above manner 
  1038. until you push F6 again or push the ENTER key.  
  1039.  
  1040. KEY TO PUSH AFTER F6 TO ENTER CHARACTERS 128 to 255 WITH EZ  
  1041.  
  1042.  
  1043. 128 ctrl-@               160 space
  1044. 129 ctrl-A               161 !
  1045. 130 ctrl-B               162 "
  1046. 131 ctrl-C               163 #
  1047. 132 ctrl-D               164 $
  1048. 133 ctrl-E               165 %
  1049. 134 ctrl-F               166 &
  1050. 135 ctrl-G               167 '
  1051. 136 ctrl-H               168 (
  1052. 137 ctrl-I               169 )
  1053. 138 ctrl-J               170 *
  1054. 139 ctrl-K               171 +
  1055. 140 ctrl-L               172 ,
  1056. 141 ctrl-M               173 -
  1057. 142 ctrl-N               174 .
  1058. 143 ctrl-O               175 /
  1059. 144 ctrl-P               176 0
  1060. 145 ctrl-Q               177 1
  1061. 146 ctrl-R               178 2
  1062. 147 ctrl-S               179 3
  1063. 148 ctrl-T               180 4
  1064. 149 ctrl-U               181 5
  1065. 150 ctrl-V               182 6
  1066. 151 ctrl-W               183 7
  1067. 152 ctrl-X               184 8
  1068. 153 ctrl-Y               185 9
  1069. 154 ctrl-Z               186 :
  1070. 155 ctrl-[               187 ;
  1071. 156 ctrl-\               188 <
  1072. 157 ctrl-]               189 =
  1073. 158 ctrl-^               190 >
  1074. 159 ctrl-_               191 ?
  1075.                                                        
  1076.  
  1077.